package cn.guo.dao.impl;


import java.util.List;

import cn.guo.dao.IFilmTypeDao;
import cn.guo.entity.FilmType;


public class FilmTypeDao extends BaseDao<FilmType> implements IFilmTypeDao {

	@SuppressWarnings("unchecked")
	public List<FilmType> getAll(String name) {
		return getSessionFactory().getCurrentSession()//
			.createQuery("from FilmType where name like ?")//
			.setParameter(0, "%" +name + "%")//
			.list();
	}

}